#include <algorithm>
#include<iostream>
#include<set>
#include<vector>
using namespace std;
class Solution {
public:
    int minimumOperations(vector<int>& nums) {
        sort(nums.begin(),nums.end());
        nums.erase(unique(nums.begin(),nums.end()),nums.end());
        int i=0;
        while(i<nums.size()&&nums[i]==0)i++;
        return nums.size()-i;

    }
};
class Solution1 {
public:
    int minimumOperations(vector<int>& nums) {
        set<int>ans;
        for(auto c:nums)ans.insert(c);
        if(!*ans.begin())return ans.size()-1;
        return ans.size();

    }
};